/*
 * 文件名称: MyAppender.java Copyright 2011-2016 Ximalaya All right reserved.
 */
package com.zxy.log4jdemo;

import org.apache.log4j.DailyRollingFileAppender;
import org.apache.log4j.Priority;

/**
 * @author Bird Zhang
 */
public class MyAppender extends DailyRollingFileAppender {
  @Override
  public boolean isAsSevereAsThreshold(Priority priority) {
    // 只判断是否相等，而不判断优先级
    return this.getThreshold().equals(priority);
  }
}
